package com.alliance.shuwei.entity;

import java.util.List;

import javax.persistence.CollectionTable;
import javax.persistence.Column;
import javax.persistence.ElementCollection;
import javax.persistence.Embedded;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

@Entity
@Table(name = "culture_resource")
public class CultureResource extends Auditable {
	@Id
	@GeneratedValue
	@Column(name = "culture_resource_id")
	private long id;
	@ManyToOne
	@JoinColumn(name = "category_id")
	private Category category;
	private String name;
	private String nameAbbreviation;
	private String type;
	private String profile;
	private String description;
	private boolean display;
	@ElementCollection
	@CollectionTable(name="resource_pictures", joinColumns=@JoinColumn(name="culture_resource_id"))
	@Column(name="picture")
	private List<String> pictures;
	@ManyToOne
	@JoinColumn(name="resource_provider_id")
	private ResourceProvider resourceProvider;
	@Embedded
	private Price price;
	public long getId() {
		return id;
	}
	public void setId(long id) {
		this.id = id;
	}
	public Category getCategory() {
		return category;
	}
	public void setCategory(Category category) {
		this.category = category;
	}
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	public String getNameAbbreviation() {
		return nameAbbreviation;
	}
	public void setNameAbbreviation(String nameAbbreviation) {
		this.nameAbbreviation = nameAbbreviation;
	}
	public String getType() {
		return type;
	}
	public void setType(String type) {
		this.type = type;
	}
	public String getProfile() {
		return profile;
	}
	public void setProfile(String profile) {
		this.profile = profile;
	}
	public String getDescription() {
		return description;
	}
	public void setDescription(String description) {
		this.description = description;
	}
	public boolean isDisplay() {
		return display;
	}
	public void setDisplay(boolean display) {
		this.display = display;
	}
	public List<String> getPictures() {
		return pictures;
	}
	public void setPictures(List<String> pictures) {
		this.pictures = pictures;
	}
	public ResourceProvider getResourceProvider() {
		return resourceProvider;
	}
	public void setResourceProvider(ResourceProvider resourceProvider) {
		this.resourceProvider = resourceProvider;
	}
	public Price getPrice() {
		return price;
	}
	public void setPrice(Price price) {
		this.price = price;
	}
	
}
